public class t4 {
    public static void main(String[] args) {
        int totalMoney = 100; // 总金额，单位为角
        int oneYuan = 0; // 1元纸币的数量

        for (oneYuan = 0; oneYuan <= 9; oneYuan++) {
            int remainJiao = totalMoney - oneYuan * 10;
            if (remainJiao % 5 == 0) {
                // 计算5角硬币的数量
                int fiveJiao = remainJiao / 5;
                // 打印兑换方式
                System.out.println("换 1 元纸币 " + oneYuan + " 张，5 角硬币 " + fiveJiao + " 个");
            }
        }
    }
}
